<?php
$a = array("test", 3=>"auch test", "note"=>1, 4=>"vier", 1=>array(6=>1));
print_r($a);

$ab = array_slice($a, 1, 2);
print_r($ab);

$ab = array_slice($a, 2, -3);
print_r($ab);

$ab = array_slice($a, -2, 3);
print_r($ab);

$ab = array_slice($a, -5, -3);
print_r($ab);

$ab = array_slice($a, 1, -2);
print_r($ab);

$ab = array_slice($a, 2);
print_r($ab);

$ab = array_slice($a, 2, -1, true);
print_r($ab);

$ab = array_slice($a, 2, -1);
print_r($ab);
echo "<br />\n";

$a = array();
$a[0] = "test";
$a[3] = "auch test";
$a["note"] = 1;
$a[] = "vier";
$a[1][6] = 7;
print_r($a);

foreach ($a as $k => $v)
{
	echo "$k => $v";
}
echo "<br />\n";

$a = array();
$a[1] = "bla";
$a[] = "blubb";
$a[1][3] = 1;
$a[1][2] ='x';
print_r($a);

foreach ($a as $k => $v)
{
	echo "$k => $v";
}
echo "<br />\n";

$a = array();
$a[1] = "bla";
$a['b'] = "blubb";
$a[1][3] = 1;
$a[1][2] ='x';
$a[1]['1'] = "Yes";
$a[][] = 'sieben';
print_r($a);

foreach ($a as $k => $v)
{
	echo "$k => $v";
}
echo "<br />\n";